-
Notifications
You must be signed in to change notification settings - Fork 1k
Add system properties bridge #15339
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add system properties bridge #15339
Conversation
|
@trask I really like this new bridge based on your idea 😄 |
3a9e285 to
9ae95f1
Compare
...on-api/src/main/java/io/opentelemetry/instrumentation/api/internal/ConfigPropertiesUtil.java
Outdated
Show resolved
Hide resolved
...on-api/src/main/java/io/opentelemetry/instrumentation/api/internal/ConfigPropertiesUtil.java
Outdated
Show resolved
Hide resolved
...on-api/src/main/java/io/opentelemetry/instrumentation/api/internal/ConfigPropertiesUtil.java
Show resolved
Hide resolved
| /** Returns true if the given OpenTelemetry instance supports Declarative Config. */ | ||
| public static boolean isDeclarativeConfig(OpenTelemetry openTelemetry) { | ||
| return isIncubator && openTelemetry instanceof ExtendedOpenTelemetry; | ||
| } | ||
|
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is isIncubator needed, since instrumentation-api (unfortunately) already depends on the api-incubator?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
only for the test (see last comment)
0138d4f to
16e62ea
Compare
|
I have no idea what could have caused this failure: |
CrashEarlyJdk8 fails when you use lambdas too early in the agent initalization. |
thank you! |
|
@trask please check again |
cf18ce0 to
18d719d
Compare
...va/io/opentelemetry/instrumentation/awssdk/v2_2/internal/AbstractAwsSdkTelemetryFactory.java
Outdated
Show resolved
Hide resolved
|
@trask I've split the PR - please have another look |
...ap/src/main/java/io/opentelemetry/javaagent/bootstrap/servlet/ExperimentalSnippetHolder.java
Outdated
Show resolved
Hide resolved
...sting/src/main/java/io/opentelemetry/instrumentation/awssdk/v2_2/AbstractAws2ClientTest.java
Outdated
Show resolved
Hide resolved
...va/io/opentelemetry/instrumentation/awssdk/v2_2/internal/AbstractAwsSdkTelemetryFactory.java
Outdated
Show resolved
Hide resolved
.../java/io/opentelemetry/instrumentation/awssdk/v1_11/autoconfigure/TracingRequestHandler.java
Outdated
Show resolved
Hide resolved
2df0753 to
6c889a7
Compare
|
@trask please check again |
trask
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nice
...va/io/opentelemetry/instrumentation/awssdk/v2_2/internal/AbstractAwsSdkTelemetryFactory.java
Outdated
Show resolved
Hide resolved
...ap/src/main/java/io/opentelemetry/javaagent/bootstrap/servlet/ExperimentalSnippetHolder.java
Outdated
Show resolved
Hide resolved
...api/src/main/java/io/opentelemetry/instrumentation/api/instrumenter/InstrumenterBuilder.java
Show resolved
Hide resolved
|
…tal-foo" and "experimental.foo" that both translate to "foo/development"
…tal-foo" and "experimental.foo" that both translate to "foo/development"
…tal-foo" and "experimental.foo" that both translate to "foo/development"
…tal-foo" and "experimental.foo" that both translate to "foo/development"
…tal-foo" and "experimental.foo" that both translate to "foo/development"
09046a2 to
c5bfe9c
Compare
|
closed in favor of #15656 |
to bridge system properties / env vars to declarative config
Fixes #14192
Alternative implementation for #14767
Breaking Changes
Rename
otel.experimental.javascript-snippettootel.instrumentation.servlet.experimental.javascript-snippetto follow naming conventionsOverview
AgentInstrumentationConfig.get().getString(TRACE_METHODS_CONFIG)ConfigPropertiesUtil.getString(GlobalOpenTelemetry.get(), "servlet", "javascript-snippet/development")config.getBoolean("otel.instrumentation.common.default-enabled", true)1ConfigPropertiesUtil.getBoolean(openTelemetry, "jdbc", "capture_query_parameters/development")Footnotes
InstrumentationConfig is implemented for agent and spring starter, but there is public API
that takes InstrumentationConfig as input in library code,
e.g. DefaultHttpServerInstrumenterBuilder (
incubating, internal). ↩